<div ng-include="'html/component/nav.html'" ng-controller="NavCtrl"></div>
<ul class="set_item" ng-include="'html/component/left_nav.html'" ng-controller="SettingNavCtrl"></ul>
<div class="set_box">
    <h1 class="set_title"><!--设置配置项-->{{language.TIPS_SET_CONFIG}}</h1>
    <div class="set_cont common_set">
        <div class="navbar">
            <ul class="navbar_ul navbar_ul_4">
                <li>
                    <a ng-class='switch_01'  ng-click = 'tab_common_list();' ng-model = 'common_cur' ><!--通用--> {{language.TIPS_SET_COMMON}} </a>
                </li>
                <li>
                    <a ng-class='switch_02'  ng-click = 'tab_cashier_list();' ng-model="cashier_cur" ><!--收银--> {{language.TIPS_SET_CASHIER}}</a>
                </li>
                <li>
                    <a ng-class='switch_03'  ng-click = 'tab_member_list();' ng-model="member_cur" ><!--会员-->{{language.TIPS_SET_MEMBER}}</a>
                </li>
                <li>
                    <a ng-class='switch_04'  ng-click = 'tab_wailian_list();' ng-model="wailian_cur" ><!--外链-->{{language.TIPS_SET_WAILIAN}}</a>
                </li>
            </ul>
        </div>
        <div id="one" ng-show = "common_cur == '1'" class="common_table_wrap">
            <table class="common_table">
                <tr>
                    <td class="name"><label for="txt_api_url"><!--客户代码-->{{language.TIPS_KEHU_CODE}}:</label></td>
                    <td class="val">
                        <input ng-model="shanghu" type="text" id="txt_shanghu_code" value="" />
                    </td>
                </tr>
				<tr>
                    <td class="name"><label for="txt_api_password"><!--密码-->{{language.TIPS_PASSWORD}}:</label></td>
                    <td class="val">
                        <input ng-model="shanghu_password" type="password" id="txt_api_password"/>
                    </td>
                </tr>
                <tr>
                    <td class="name"><label for="txt_api_url"><!--服务器-->{{language.TIPS_SET_SERVER}}:</label></td>
                    <td class="val">
                        <input ng-model="configData.api_url" type="text" id="txt_api_url" value="" /><i class="help" id="help_server" ng-click="help_prompt(language.HELP_PROMPT_SERVER, 'help_server')"></i>
                    </td>
                </tr>
                <tr>
                    <td class="name"><label for=""><!--旋转-->{{language.TIP_SET_XUANZHUAN}}:</label></td>
                    <td class="val">
                        <p class="radio_wrap">
                            <input ng-model="configData.xuanzhuan" type="radio"  name= "txt_xz_switch" class="txt_xz_switch" id="txt_xz_switch0" value="0" />
                            <label for="txt_xz_switch0" ng-class="{true:'curr',false:''}[configData.xuanzhuan == 0]"><!--向左-->{{language.TIP_SET_LEFT}}</label>
                            <input ng-model="configData.xuanzhuan" type="radio"  name= "txt_xz_switch" class="txt_xz_switch" id="txt_xz_switch1" value="1" />
                            <label for="txt_xz_switch1" ng-class="{true:'curr',false:''}[configData.xuanzhuan == 1]"><!--向右-->{{language.TIP_SET_RIGHT}}</label>
                        </p><i class="help" id="help_xz" ng-click="help_prompt(language.HELP_PROMPT_XZ, 'help_xz')"></i></td>
                </tr>
                <tr>
                    <td class="name"><label for=""><!--语言设置-->{{language.TIP_SET_LANGUAGE}}:</label></td>
                    <td class="val">
                        <p class="radio_wrap">
                            <input ng-model="configData.language" type="radio"  name= "txt_yy_switch" class="txt_yy_switch" id="txt_yy_switch0" value="zh_cn" />
                            <label for="txt_yy_switch0" ng-class="{true:'curr',false:''}[configData.language == 'zh_cn']"><!--简体中文-->{{language.TIP_SET_CHINESE}}</label>
                            <input ng-model="configData.language" type="radio"  name= "txt_yy_switch" class="txt_yy_switch" id="txt_yy_switch1" value="zh_tw" />
                            <label for="txt_yy_switch1" ng-class="{true:'curr',false:''}[configData.language == 'zh_tw']"><!--繁体中文-->{{language.TIP_SET_FANTI}}</label>
                            <input ng-model="configData.language" type="radio"  name= "txt_yy_switch" class="txt_yy_switch" id="txt_yy_switch2" value="en" />
                            <label for="txt_yy_switch2" ng-class="{true:'curr',false:''}[configData.language == 'en']"><!--英语-->{{language.TIP_SET_ENGLISH}}</label>
                        </p><i class="help" id="help_language" ng-click="help_prompt(language.HELP_PROMPT_LANGUAGE, 'help_language')"></i></td>
                </tr>
                <tr>
                    <td class="name"><label for=""><!-- 货号模糊匹配: -->{{language.TIPS_SETTING_MATCH}}</label></td>
                    <td class="val">
                        <p class="radio_wrap">
                            <input ng-model="configData.searchMacthType" type="radio"  name= "txt_match_switch" class="txt_match_switch" id="txt_match_switch0" value="match_head" />
                            <label for="txt_match_switch0" ng-class="{true:'curr',false:''}[configData.searchMacthType == 'match_head']"><!-- 按首位模糊匹配 -->{{language.TIPS_SETTING_MATCH_HEAD}}</label>
                            <input ng-model="configData.searchMacthType" type="radio"  name= "txt_match_switch" class="txt_match_switch" id="txt_match_switch1" value="match_tail" />
                            <label for="txt_match_switch1" ng-class="{true:'curr',false:''}[configData.searchMacthType == 'match_tail']"><!-- 按尾号模糊匹配 -->{{language.TIPS_SETTING_MATCH_TAIL}}</label>
                            <input ng-model="configData.searchMacthType" type="radio"  name= "txt_match_switch" class="txt_match_switch" id="txt_match_switch2" value="match_any" />
                            <label for="txt_match_switch2" ng-class="{true:'curr',false:''}[configData.searchMacthType == 'match_any']"><!-- 全模糊匹配 -->{{language.TIPS_SETTING_MATCH_ANY}}</label>
                        </p><i class="help" id="help_match" ng-click="help_prompt(language.HELP_PROMPT_MATCH, 'help_match')"></i></td>
                </tr>
                <!--默认输入项-->
                <tr>
                    <td class="name"><label for="">{{language.INPUT_CHENCKED}}:</label></td>
                    <td class="val">
                        <p class="radio_wrap">
                            <input ng-model="configData.default_input" type="radio"  name= "txt_nl_switch" class="txt_nl_switch" id="1txt_nl_switch" value="0" />
                            <label for="1txt_nl_switch" ng-class="{true:'curr',false:''}[configData.default_input == 0]"> <!--会员-->{{language.TIPS_VIP}}</label>
                            <input ng-model="configData.default_input" type="radio"  name= "txt_nl_switch" class="txt_nl_switch" id="2txt_nl_switch1" value="1" />
                            <label for="2txt_nl_switch1" ng-class="{true:'curr',false:''}[configData.default_input == 1]"><!--商品-->{{language.TIPS_CASHIER_GOODS}}</label>
                            <input ng-model="configData.default_input" type="radio"  name= "txt_nl_switch" class="txt_nl_switch" id="3txt_nl_switch1" value="2" />
                            <label for="3txt_nl_switch1" ng-class="{true:'curr',false:''}[configData.default_input == 2]"><!--优惠券-->{{language.MSG_COUPON}}</label>
                        </p><i class="help" id="help_membAge" ng-click="help_prompt(language.HELP_PROMPT_default_input, 'help_membAge')">
                    </td>
                </tr>
            
                <!--
                <tr>
                    <td class="name"><label for="">{{language.TIPS_SETTING_MODE_SET}}:</label></td>
                    <td class="val"><select ng-change="change(runMode_select)" ng-model="runMode_select" ng-options="tpl.name for tpl in runMode_options"></select><i class="help" id="help_runMode" ng-click="help_prompt(language.HELP_PROMPT_RUNMODE}}','help_runMode')"></i></td>
                </tr>
                <tr ng-show="runMode_select.id == 1">
                    <td class="name"><label for="txt_ip">{{language.TIPS_SETTING_IP_ADDRESS}}:</label></td>
                    <td class="val">
                        <input ng-model="ip" type="text" id="txt_ip" value="" readonly="true"/>
                    </td>
                </tr>
                <tr ng-show="runMode_select.id == 1">
                    <td class="name"><label for="txt_port">{{language.TIPS_SETTING_PORT}}:</label></td>
                    <td class="val">
                        <input ng-model="port" type="text" id="txt_port" value="" readonly="true"/>
                    </td>
                </tr>
                <tr ng-show="runMode_select.id == 2">
                    <td class="name"><label for="txt_url">{{language.TIPS_SETTING_HOST_INTERFACE}}:</label></td>
                    <td class="val">
                        <input ng-model="url" type="text" id="txt_url" value="" />
                    </td>
                </tr>
                -->
            </table>
        </div>
        <div id="two" ng-show = "cashier_cur == '1'" class="common_table_wrap">
            <table class="common_table">
                <tr>
                    <td class="name"><label for=""><!--收银输入设置-->{{language.TIPS_SET_CHSHIER_INPUT}}:</label></td>
                    <td class="val">
                        <p class="radio_wrap">
                            <input ng-model="configData.keyboard" type="radio" name="txt_keyboard_switch" class="txt_keyboard_switch" id="txt_keyboard_switch0" value="0" />
                            <label for="txt_keyboard_switch0" ng-class="{true:'curr',false:''}[configData.keyboard == 0]"><!--数字小键盘-->{{language.TIPS_SET_NUMBER_KEYPAD}}</label>
                            <input ng-model="configData.keyboard" type="radio" name="txt_keyboard_switch" class="txt_keyboard_switch" id="txt_keyboard_switch1" value="1" />
                            <label for="txt_keyboard_switch1" ng-class="{true:'curr',false:''}[configData.keyboard == 1]"><!--系统全键盘-->{{language.TIPS_SET_SYSTEM_FULL_KEY}}</label>
                        </p><i class="help" id="help_keyboard" ng-click="help_prompt(language.HELP_PROMPT_KEYBOARD, 'help_keyboard')"></i></td>
                </tr>
                <tr>
                    <td class="name"><label for=""><!--收银导购设置-->{{language.TIPS_SET_CASHIE_GUIDE}}:</label></td>
                    <td class="val">
                        <p class="radio_wrap">
                            <input ng-model="configData.daogou" type="radio" name="txt_daogou_switch" class="txt_daogou_switch" id="txt_daogou_switch0" value="0" />
                            <label for="txt_daogou_switch0" ng-class="{true:'curr',false:''}[configData.daogou == 0]"><!--单导购-->{{language.TIPS_SET_SINGLE_GUIDE}}</label>
                            <input ng-model="configData.daogou" type="radio" name="txt_daogou_switch" class="txt_daogou_switch" id="txt_daogou_switch1" value="1" />
                            <label for="txt_daogou_switch1" ng-class="{true:'curr',false:''}[configData.daogou == 1]"><!--多导购-->{{language.TIPS_SET_MORE_GUIDE}}</label>
                        </p><i class="help" id="help_daogou" ng-click="help_prompt(language.HELP_PROMPT_DAOGOU, 'help_daogou')"></i></td>
                </tr>
                <tr>
                    <td class="name"><label for=""><!--是否允许抹零-->{{language.TIPS_SET_IF_ALLOW_WIPE_CHANGE}}:</label></td>
                    <td class="val">
                        <p class="radio_wrap">
                            <input ng-model="configData.moling" type="radio" name="txt_moling_switch" class="txt_moling_switch" id="txt_moling_switch0" value="0" />
                            <label for="txt_moling_switch0" ng-class="{true:'curr',false:''}[configData.moling == 0]"><!--不许-->{{language.TIPS_SET_NOT_ALLOW}} </label>
                            <input ng-model="configData.moling" type="radio" name="txt_moling_switch" class="txt_moling_switch" id="txt_moling_switch1" value="1" />
                            <label for="txt_moling_switch1" ng-class="{true:'curr',false:''}[configData.moling == 1]"><!--允许-->{{language.TIPS_SET_ALLOW}} </label>
                        </p><i class="help" id="help_moling" ng-click="help_prompt(language.HELP_PROMPT_MOLING, 'help_moling')"></i></td>
                </tr>
                <tr ng-show="configData.moling == 1">
                    <td class="name"><label for=""><!--抹零位数-->{{language.TIPS_SET_WIPE_CHANGE}}:</label></td>
                    <td class="val">
                        <p class="radio_wrap">
                            <input ng-model="configData.molingtype"  type="radio" name="txt_moling_type" class="txt_moling_type" id="txt_moling_type0" value="0" />
                            <label for="txt_moling_type0" ng-class="{true:'curr',false:''}[configData.molingtype == 0]"><!--元-->{{language.TIPS_SET_YUAN}}</label>
                            <input ng-model="configData.molingtype" type="radio" name="txt_moling_type" class="txt_moling_type" id="txt_moling_type1" value="1" />
                            <label for="txt_moling_type1" ng-class="{true:'curr',false:''}[configData.molingtype == 1]"><!--角-->{{language.TIPS_SET_JIAO}}</label>
                        </p></td>
                </tr>
                <tr ng-show="configData.moling == 1">
                    <td class="name"><label for=""><!-- 抹零规则: -->{{language.TIPS_SETTING_MOLING_RULE}}</label></td>
                    <td class="val">
                        <p class="radio_wrap">
                            <input ng-model="configData.molingRule"  type="radio" name="txt_moling_type" class="txt_moling_rule" id="txt_moling_rule0" value="moling_rule_sswr" />
                            <label for="txt_moling_rule0" ng-class="{true:'curr',false:''}[configData.molingRule == 'moling_rule_sswr']"><!-- 四舍五入 -->{{language.TIPS_SETTING_MOLING_ROUND}}</label>
                            <input ng-model="configData.molingRule" type="radio" name="txt_moling_type" class="txt_moling_rule" id="txt_moling_rule1" value="moling_rule_sw" />
                            <label for="txt_moling_rule1" ng-class="{true:'curr',false:''}[configData.molingRule == 'moling_rule_sw']"><!-- 舍位 -->{{language.TIPS_SETTING_MOLING_FLOOR}}</label>
                            <input ng-model="configData.molingRule" type="radio" name="txt_moling_type" class="txt_moling_rule" id="txt_moling_rule2" value="moling_rule_jw" />
                            <label for="txt_moling_rule2" ng-class="{true:'curr',false:''}[configData.molingRule == 'moling_rule_jw']"><!-- 进位 -->{{language.TIPS_SETTING_MOLING_CEIL}}</label>
                        </p></td>
                </tr>
                <tr ng-show="{{purview['\/CashierReturnCtrl\/Without_receipt'].show}}">
                    <td class="name"><label for=""><!--无票退货-->{{language.TIPS_SETTING_RETURN_WITHOUT_RECEIPT}}:</label></td>
                    <td class="val">
                        <p class="radio_wrap">
                            <input ng-model="configData.no_ticket_return" type="radio"  name= "txt_ntr_switch" class="txt_ntr_switch" id="txt_ntr_switch0" value="0" />
                            <label for="txt_ntr_switch0" ng-class="{true:'curr',false:''}[configData.no_ticket_return == 0]"><!--否-->{{language.COMMON_NO}}</label>
                            <input ng-model="configData.no_ticket_return" type="radio"  name= "txt_ntr_switch" class="txt_ntr_switch" id="txt_ntr_switch1" value="1" />
                            <label for="txt_ntr_switch1" ng-class="{true:'curr',false:''}[configData.no_ticket_return == 1]"><!--是-->{{language.COMMON_YES}}</label>
                        </p><i class="help" id="help_ntr" ng-click="help_prompt(language.HELP_PROMPT_NTR, 'help_ntr')"></i></td>
                </tr>
				
                <tr>
                    <td class="name"><label for="txt_commonpay_num"><!--常用支付数-->{{language.TIPS_SET_COIN_NUM}}:</label></td>
                    <td class="val">
                        <input ng-model="configData.commonpay_num" type="number" id="txt_commonpay_num" value="" /><i class="help" id="help_commonNum" ng-click="help_prompt(language.HELP_PROMPT_COMMONNUM, 'help_commonNum')"></i>
                    </td>
                </tr>

                <tr>
                    <td class="name"><label for=""><!--多币种-->{{language.TIPS_SET_COIN_FOREIGN}}:</label></td>
                    <td class="val">
                        <p class="radio_wrap">
                            <input ng-model="configData.currency_foreign" type="radio" name="txt_foreign_switch" class="txt_foreign_switch" id="txt_foreign_switch0" value="0" />
                            <label for="txt_foreign_switch0" ng-class="{true:'curr',false:''}[configData.currency_foreign == 0]"><!--否-->{{language.COMMON_NO}} </label>
                            <input ng-model="configData.currency_foreign" type="radio" name="txt_foreign_switch" class="txt_foreign_switch" id="txt_foreign_switch1" value="1" />
                            <label for="txt_foreign_switch1" ng-class="{true:'curr',false:''}[configData.currency_foreign == 1]"><!--是-->{{language.COMMON_YES}} </label>
                        </p>
                        <i class="help" id="help_foreign" ng-click="help_prompt(language.HELP_COIN_FOREIGN, 'help_foreign')"></i>
                    </td>
                </tr>
                <tr  ng-show="configData.currency_foreign == 1">
                    <td class="name"><label><!--默认币种-->{{language.TIPS_SET_COIN_DEFAULT}}:</label></td>
                    <td class="val">
                        <select ng-model="configData.standard_coin" ng-options="tpl.cur_code as tpl.cur_name for tpl in currencylist">
                        </select>
                        <i class="help" id="help_receiptCoin" ng-click="help_prompt(language.HELP_COIN, 'help_receiptCoin')"></i>
                    </td>
                </tr>
            </table>
        </div>
        <div id="three" ng-show = "member_cur == '1'" class="common_table_wrap">
            <table class="common_table">
                <tr>
                    <td class="name"><label for=""><!--年龄设置-->{{language.TIP_SET_AGE}}:</label></td>
                    <td class="val">
                        <p class="radio_wrap">
                            <input ng-model="configData.membAge" type="radio"  name= "txt_nl_switch" class="txt_nl_switch" id="txt_nl_switch0" value="0" />
                            <label for="txt_nl_switch0" ng-class="{true:'curr',false:''}[configData.membAge == 0]"><!--关闭-->{{language.TIP_SET_CLOSE}}</label>
                            <input ng-model="configData.membAge" type="radio"  name= "txt_nl_switch" class="txt_nl_switch" id="txt_nl_switch1" value="1" />
                            <label for="txt_nl_switch1" ng-class="{true:'curr',false:''}[configData.membAge == 1]"><!--开启-->{{language.TIP_SET_START}}</label>
                        </p><i class="help" id="help_membAge" ng-click="help_prompt(language.HELP_PROMPT_MEMBAGE, 'help_membAge')"></td>
                </tr>
            </table>
        </div>
        <div id="four" ng-show = "wailian_cur == '1'" class="common_table_wrap">
            <table class="common_table_type2">
                <tr> 
                    <th width="80">位置</th>
                    <th>标题</th>
                    <th width="50%">地址</th>
                    <th width="150">状态</th>
                </tr>
                <tr>
                    <td>链接1</td>
                    <td><input type="text" ng-model="configData.outlink[0].name"/></td>
                    <td><input type="text" ng-model="configData.outlink[0].url"/></td>
                    <td class="val">
                        <p class="radio_wrap">
                            <input ng-model="configData.outlink[0].status" type="radio"  name= "txt_outlink_switch" class="txt_link_switch" id="txt_outlink_switch0" value="0" />
                            <label for="txt_outlink_switch0" ng-class="{true:'curr',false:''}[configData.outlink[0].status == 0]"><!--关闭-->{{language.TIP_SET_CLOSE}}</label>
                            <input ng-model="configData.outlink[0].status" type="radio"  name= "txt_outlink_switch" class="txt_outlink_switch" id="txt_outlink_switch1" value="1" />
                            <label for="txt_outlink_switch1" ng-class="{true:'curr',false:''}[configData.outlink[0].status == 1]"><!--开启-->{{language.TIP_SET_START}}</label>
                        </p>
                    </td>
                </tr>
                <tr>
                    <td>链接2</td>
                    <td><input type="text" ng-model="configData.outlink[1].name"/> </td>
                    <td><input type="text" ng-model="configData.outlink[1].url"/></td>
                    <td class="val">
                        <p class="radio_wrap">
                            <input ng-model="configData.outlink[1].status" type="radio"  name= "txt_outlink_switch" class="txt_link_switch" id="txt_outlink1_switch0" value="0" />
                            <label for="txt_outlink1_switch0" ng-class="{true:'curr',false:''}[configData.outlink[1].status == 0]"><!--关闭-->{{language.TIP_SET_CLOSE}}</label>
                            <input ng-model="configData.outlink[1].status" type="radio"  name= "txt_outlink_switch" class="txt_outlink_switch" id="txt_outlink1_switch1" value="1" />
                            <label for="txt_outlink1_switch1" ng-class="{true:'curr',false:''}[configData.outlink[1].status == 1]"><!--开启-->{{language.TIP_SET_START}}</label>
                        </p>
                    </td>
                </tr>
                <tr>
                    <td>链接3</td>
                    <td><input type="text" ng-model="configData.outlink[2].name"/> </td>
                    <td><input type="text" ng-model="configData.outlink[2].url"/></td>
                    <td class="val">
                        <p class="radio_wrap">
                            <input ng-model="configData.outlink[2].status" type="radio"  name= "txt_outlink_switch" class="txt_link_switch" id="txt_outlink2_switch0" value="0" />
                            <label for="txt_outlink2_switch0" ng-class="{true:'curr',false:''}[configData.outlink[2].status == 0]"><!--关闭-->{{language.TIP_SET_CLOSE}}</label>
                            <input ng-model="configData.outlink[2].status" type="radio"  name= "txt_outlink_switch" class="txt_outlink_switch" id="txt_outlink2_switch1" value="1" />
                            <label for="txt_outlink2_switch1" ng-class="{true:'curr',false:''}[configData.outlink[2].status == 1]"><!--开启-->{{language.TIP_SET_START}}</label>
                        </p>
                    </td>
                </tr>
                <tr>
                    <td>链接4</td>
                    <td><input type="text" ng-model="configData.outlink[3].name"/> </td>
                    <td><input type="text" ng-model="configData.outlink[3].url"/></td>
                    <td class="val">
                        <p class="radio_wrap">
                            <input ng-model="configData.outlink[3].status" type="radio"  name= "txt_outlink_switch" class="txt_link_switch" id="txt_outlink3_switch0" value="0" />
                            <label for="txt_outlink3_switch0" ng-class="{true:'curr',false:''}[configData.outlink[3].status == 0]"><!--关闭-->{{language.TIP_SET_CLOSE}}</label>
                            <input ng-model="configData.outlink[3].status" type="radio"  name= "txt_outlink_switch" class="txt_outlink_switch" id="txt_outlink3_switch1" value="1" />
                            <label for="txt_outlink3_switch1" ng-class="{true:'curr',false:''}[configData.outlink[3].status == 1]"><!--开启-->{{language.TIP_SET_START}}</label>
                        </p>
                    </td>
                </tr>
            </table>
        </div>
        <p class="common_btn_wrap">
            <button type="button" id="btn_setting_save" ng-click="processForm()">
                <!--确认-->
                {{language.ACT_CONFIRM}}
            </button>
            <button type="button" ng-click="resetForm();">
                <!--重置-->
                {{language.ACT_RESET}}
            </button>
        </p>
    </div>
</div>
